<!--
  @author heguanghua
  @since 2019/06/12 11:57
-->
<!DOCTYPE html SYSTEM "http://www.thymeleaf.org/dtd/xhtml1-strict-thymeleaf-4.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:th="http://www.thymeleaf.org">

<table class="layui-hide" id="zmn-table" lay-filter="zmn-table" th:fragment="table">
    <thead>
    <tr>
        <th lay-data="{field:'channelId', width:180, unresize:true, align:'center'}">价格表类型</th>
        <th lay-data="{field:'discount', width:230, unresize:true, align:'center'}">价格表名称</th>
        <th lay-data="{field:'ratio', width:120, unresize:true, align:'center'}">定价方式</th>
        <th lay-data="{field:'status', width:200, unresize:true, align:'center'}">价格表状态</th>
        <th lay-data="{field:'操作', unresize:true, align:'center', fixed:'right'}">操作</th>
    </tr>
    </thead>
    <tbody>
    <tr>
        <td>服务价格</td>
        <td th:text="${items.get(0).tariffName}"></td>
        <td th:text="${items.get(0).priceType == null ? '':items.get(0).priceType == 1 ? '系数定价': '城市定价'}"></td>
        <td th:text="${items.get(0).status == null ? '':items.get(0).status == 1 ? '停用': '启用'}"></td>
        <td>
            <a style="color: #00a0e9" href="javascript:void(0)"
               th:onclick="selectPriceTable([[${channelRatio.channelId}]], [[${bizType}]], 1);">选择价格表</a>
            <a style="color: #00a0e9"
               th:lay-href="|/product/tariff/item/price.action?&channelId=${channelId}&bizType=${bizType}&tariffType=1|">查看价格表</a>
        </td>
    </tr>
    <tr>
        <td>计价器价格</td>
        <td th:text="${items.get(1).tariffName}"></td>
        <td th:text="${items.get(1).priceType == null ? '':items.get(1).priceType == 1 ? '系数定价': '城市定价'}"></td>
        <td th:text="${items.get(1).status == null ? '':items.get(1).status == 1 ? '停用': '启用'}"></td>
        <td>
            <a style="color: #00a0e9" href="javascript:void(0)"
               th:onclick="selectPriceTable([[${channelRatio.channelId}]], [[${bizType}]], 2);">选择价格表</a>
            <a style="color: #00a0e9"
               th:lay-href="|/product/tariff/item/price.action?&channelId=${channelId}&bizType=${bizType}&tariffType=2|">查看价格表</a>
        </td>
    </tr>
    <tr>
        <td>提前付价格</td>
        <td th:text="${items.get(2).tariffName}"></td>
        <td th:text="${items.get(2).priceType == null ? '':items.get(2).priceType == 1 ? '系数定价': '城市定价'}"></td>
        <td th:text="${items.get(2).status == null ? '':items.get(2).status == 1 ? '停用': '启用'}"></td>
        <td>
            <a style="color: #00a0e9" href="javascript:void(0)"
               th:onclick="selectPriceTable([[${channelRatio.channelId}]], [[${bizType}]], 3);">选择价格表</a>
            <a style="color: #00a0e9"
               th:lay-href="|/product/tariff/item/price.action?&channelId=${channelId}&bizType=${bizType}&tariffType=3|">查看价格表</a>
        </td>
    </tr>
    <tr th:if="${bizType==1}">
        <td>计价器3.0价格</td>
        <td th:text="${items.get(3).tariffName}"></td>
        <td th:text="${items.get(3).priceType == null ? '':items.get(3).priceType == 1 ? '系数定价': '城市定价'}"></td>
        <td th:text="${items.get(3).status == null ? '':items.get(3).status == 1 ? '停用': '启用'}"></td>
        <td>
            <a style="color: #00a0e9" href="javascript:void(0)"
               th:onclick="selectPriceTable([[${channelRatio.channelId}]], [[${bizType}]], 4);">选择价格表</a>
            <a style="color: #00a0e9"
               th:lay-href="|/product/tariff/item/price.action?&channelId=${channelId}&bizType=${bizType}&tariffType=4|">查看价格表</a>
        </td>
    </tr>

    </tbody>
</table>
